package com.hzhr.iot.device.convertor;

import com.hzhr.iot.device.convertor.custom.*;
import com.hzhr.iot.core.util.HzhrTypeUtil;
import com.hzhr.iot.core.util.HzhrJsonUtil;
import java.util.Map;
import com.hzhr.iot.device.model.collectDevice.CollectDeviceModel;
import com.hzhr.iot.device.model.collectDevice.CollectDevicePostModel;
import com.hzhr.iot.device.model.collectDevice.CollectDevicePutModel;
import com.hzhr.iot.device.entity.CollectDeviceEntity;
import com.hzhr.iot.device.entity.ext.CollectDeviceEntityExt;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import com.hzhr.iot.device.model.collectDevice.CollectDeviceModel;
import com.hzhr.iot.device.model.collectDevice.CollectDeviceGetModel;
import com.hzhr.iot.device.model.collectDevice.CollectDevicePostModel;
import com.hzhr.iot.device.model.collectDevice.CollectDevicePutModel;
import com.hzhr.iot.device.model.collectDevice1.CollectDevice1Model;
import com.hzhr.iot.device.model.collectDevice1.CollectDevice1GetModel;
import com.hzhr.iot.device.model.collectDevice_code.CollectDevice_CodeModel;
import com.hzhr.iot.device.model.collectDevice_code.CollectDevice_CodeGetModel;
import com.hzhr.iot.device.model.collectDevice_code.CollectDevice_CodePutModel;
import com.hzhr.iot.device.model.collectDevice_statusInfo.CollectDevice_StatusInfoModel;
import com.hzhr.iot.device.model.collectDevice_statusInfo.CollectDevice_StatusInfoGetModel;
import com.hzhr.iot.device.model.collectDevice_statusInfo.CollectDevice_StatusInfoPutModel;
import com.hzhr.iot.device.model.collectDevice_valveStatus.CollectDevice_ValveStatusModel;
import com.hzhr.iot.device.model.collectDevice_valveStatus.CollectDevice_ValveStatusGetModel;
import com.hzhr.iot.device.model.collectDevice_valveStatus.CollectDevice_ValveStatusPutModel;
import com.hzhr.iot.device.model.concentrator_meter.Concentrator_MeterModel;
import com.hzhr.iot.device.model.concentrator_meter.Concentrator_MeterGetModel;
import com.hzhr.iot.device.model.concentrator_meter.Concentrator_MeterPostModel;
import com.hzhr.iot.device.model.concentrator_meter.Concentrator_MeterPutModel;
import com.hzhr.iot.device.model.regulatorDevice.RegulatorDeviceModel;
import com.hzhr.iot.device.model.regulatorDevice.RegulatorDeviceGetModel;
import com.hzhr.iot.device.queryModel.custom.CollectDeviceCustomQueryModel;

@Component
public class CollectDeviceConvertor {
    @Autowired
    AlarmDataCustomConvertor alarmDataCustomConvertor;
    @Autowired
    CollectDataCustomConvertor collectDataCustomConvertor;
    @Autowired
    CollectDeviceTypeCustomConvertor collectDeviceTypeCustomConvertor;
    @Autowired
    DeviceInfoCardCustomConvertor deviceInfoCardCustomConvertor;
    @Autowired
    DeviceMaintenanceCardCustomConvertor deviceMaintenanceCardCustomConvertor;
    @Autowired
    DeviceMaintenanceCardItemCustomConvertor deviceMaintenanceCardItemCustomConvertor;
    @Autowired
    ImplFactoryCustomConvertor implFactoryCustomConvertor;
    @Autowired
    ImplIotDeviceTypeCustomConvertor implIotDeviceTypeCustomConvertor;
    @Autowired
    ImplRecordCustomConvertor implRecordCustomConvertor;
    @Autowired
    IotDeviceCustomConvertor iotDeviceCustomConvertor;
    @Autowired
    IotDeviceTypeCustomConvertor iotDeviceTypeCustomConvertor;
    @Autowired
    OptionsCustomConvertor optionsCustomConvertor;
    @Autowired
    ProdFactoryCustomConvertor prodFactoryCustomConvertor;
    @Autowired
    RegulatorCollectDataCustomConvertor regulatorCollectDataCustomConvertor;
    @Autowired
    UserCompanyCustomConvertor userCompanyCustomConvertor;

    public CollectDeviceEntity collectDeviceModel2entity(CollectDeviceModel in) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId usingDate resourceCode regulatorDeviceProdFactory state longitude 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setDeptCode(HzhrTypeUtil.string2string(in.getDeptCode()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        result.setPressureUnit(HzhrTypeUtil.string2string(in.getPressureUnit()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        result.setCreateTime(HzhrTypeUtil.long2date(in.getCreateTime()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setOutId(HzhrTypeUtil.string2string(in.getOutId()));
        return result;
    }
    public CollectDeviceEntity collectDeviceModel2entity(CollectDeviceModel in, CollectDeviceEntity ori) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId usingDate resourceCode regulatorDeviceProdFactory state longitude 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setDeptCode(HzhrTypeUtil.string2string(in.getDeptCode()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        result.setPressureUnit(HzhrTypeUtil.string2string(in.getPressureUnit()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        result.setCreateTime(HzhrTypeUtil.long2date(in.getCreateTime()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setOutId(HzhrTypeUtil.string2string(in.getOutId()));
        return result;
    }
    public List<CollectDeviceEntity> collectDeviceModelList2entityList(List<CollectDeviceModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDeviceModel item : in) {
            result.add(collectDeviceModel2entity(item));
        }
        return result;
    }
    public CollectDeviceModel entity2collectDeviceModel(CollectDeviceEntity in) {
        //未转换字段: managementName iotDeviceTypeDes iotDeviceTypeId prodFactoryIotCompanyId iotDeviceLongitude pressureUnitDes iotDeviceCode prodFactoryDes iotDeviceDes alarmCount gasConsume prodFactoryId currentValveStatusDes iotDeviceSimTypeCode subCompanyName iotDeviceSimTypeDes iotDeviceCompanyName typeDes iotDeviceLatitude iotDeviceSimNo 
        if (in == null) return null;
        CollectDeviceModel result = new CollectDeviceModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setOutId(HzhrTypeUtil.string2string(in.getOutId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setDeptCode(HzhrTypeUtil.string2string(in.getDeptCode()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        result.setPressureUnit(HzhrTypeUtil.string2string(in.getPressureUnit()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        result.setCreateTime(HzhrTypeUtil.date2long(in.getCreateTime()));
        return result;
    }
    public List<CollectDeviceModel> entityList2collectDeviceModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDeviceModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDeviceModel(item));
        }
        return result;
    }
    public CollectDeviceModel ext2collectDeviceModel(CollectDeviceEntityExt in) {
        //未转换字段: managementName iotDeviceTypeDes iotDeviceTypeId prodFactoryIotCompanyId iotDeviceLongitude pressureUnitDes iotDeviceCode prodFactoryDes iotDeviceDes prodFactoryId currentValveStatusDes iotDeviceSimTypeCode subCompanyName iotDeviceSimTypeDes iotDeviceCompanyName typeDes iotDeviceLatitude iotDeviceSimNo 
        if (in == null) return null;
        CollectDeviceModel result = new CollectDeviceModel();

        result.setGasConsume(HzhrTypeUtil.double2double(in.getGasConsume()));
        result.setAlarmCount(HzhrTypeUtil.integer2integer(in.getAlarmCount()));
        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setOutId(HzhrTypeUtil.string2string(in.getOutId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setDeptCode(HzhrTypeUtil.string2string(in.getDeptCode()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        result.setPressureUnit(HzhrTypeUtil.string2string(in.getPressureUnit()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        result.setCreateTime(HzhrTypeUtil.date2long(in.getCreateTime()));
        return result;
    }
    public List<CollectDeviceModel> extList2collectDeviceModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDeviceModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDeviceModel(item));
        }
        return result;
    }
    public CollectDeviceGetModel extList2collectDeviceGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceModel> modelList = extList2collectDeviceModelList(extList);
        if (modelList == null) {
            CollectDeviceGetModel result = new CollectDeviceGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_gasUser = query.get("_show_gasUser") != null ? Boolean.parseBoolean(query.get("_show_gasUser").toString()) : false;
         Boolean _show_type = query.get("_show_type") != null ? Boolean.parseBoolean(query.get("_show_type").toString()) : false;
         Boolean _show_outId = query.get("_show_outId") != null ? Boolean.parseBoolean(query.get("_show_outId").toString()) : false;
         Boolean _show_iotDevice = query.get("_show_iotDevice") != null ? Boolean.parseBoolean(query.get("_show_iotDevice").toString()) : false;
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;
         Boolean _show_gasConsume = query.get("_show_gasConsume") != null ? Boolean.parseBoolean(query.get("_show_gasConsume").toString()) : false;
         Boolean _show_alarmCount = query.get("_show_alarmCount") != null ? Boolean.parseBoolean(query.get("_show_alarmCount").toString()) : false;
         Boolean _show_dept = query.get("_show_dept") != null ? Boolean.parseBoolean(query.get("_show_dept").toString()) : false;

        if (!_show_gasUser) {
            for (CollectDeviceModel model : modelList) {
                model.setGasUserCode(null);
                model.setGasUserName(null);
                model.setGasUserAddress(null);
            }
        }
        if (!_show_type) {
            for (CollectDeviceModel model : modelList) {
                model.setTypeDes(null);
                model.setProdFactoryId(null);
                model.setProdFactoryDes(null);
                model.setProdFactoryIotCompanyId(null);
            }
        }
        if (!_show_outId) {
            for (CollectDeviceModel model : modelList) {
                model.setOutId(null);
            }
        }
        if (!_show_iotDevice) {
            for (CollectDeviceModel model : modelList) {
                model.setIotDeviceCode(null);
                model.setIotDeviceDes(null);
                model.setIotDeviceTypeId(null);
                model.setIotDeviceTypeDes(null);
                model.setIotDeviceSimNo(null);
                model.setIotDeviceLongitude(null);
                model.setIotDeviceLatitude(null);
                model.setIotDeviceSimTypeCode(null);
                model.setIotDeviceSimTypeDes(null);
                model.setIotDeviceCompanyName(null);
            }
        }
        if (!_show_info) {
            for (CollectDeviceModel model : modelList) {
                model.setCode(null);
                model.setDes(null);
                model.setCategoryCode(null);
                model.setTypeId(null);
                model.setCompanyId(null);
                model.setDeptId(null);
                model.setDeptCode(null);
                model.setGasUserId(null);
                model.setIotDeviceId(null);
                model.setPressureUnit(null);
                model.setPressureUnitDes(null);
                model.setCurrentReading(null);
                model.setCurrentValveStatusCode(null);
                model.setCurrentValveStatusDes(null);
                model.setCurrentCellVoltage(null);
                model.setLastCollectTime(null);
                model.setCreateTime(null);
            }
        }
        if (!_show_gasConsume) {
            for (CollectDeviceModel model : modelList) {
                model.setGasConsume(null);
            }
        }
        if (!_show_alarmCount) {
            for (CollectDeviceModel model : modelList) {
                model.setAlarmCount(null);
            }
        }
        if (!_show_dept) {
            for (CollectDeviceModel model : modelList) {
                model.setManagementName(null);
                model.setSubCompanyName(null);
            }
        }

        CollectDeviceGetModel result = new CollectDeviceGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public CollectDeviceGetModel entity2collectDeviceGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2collectDeviceGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2collectDeviceGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity collectDevicePostModel2entity(CollectDevicePostModel in) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId pressureUnit usingDate currentReading lastCollectTime resourceCode createTime outId regulatorDeviceProdFactory id state currentCellVoltage deptCode longitude currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public CollectDeviceEntity collectDevicePostModel2entity(CollectDevicePostModel in, CollectDeviceEntity ori) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId pressureUnit usingDate currentReading lastCollectTime resourceCode createTime outId regulatorDeviceProdFactory id state currentCellVoltage deptCode longitude currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevicePostModelList2entityList(List<CollectDevicePostModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevicePostModel item : in) {
            result.add(collectDevicePostModel2entity(item));
        }
        return result;
    }
    public CollectDevicePostModel entity2collectDevicePostModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevicePostModel result = new CollectDevicePostModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDevicePostModel> entityList2collectDevicePostModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevicePostModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevicePostModel(item));
        }
        return result;
    }
    public CollectDevicePostModel ext2collectDevicePostModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevicePostModel result = new CollectDevicePostModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDevicePostModel> extList2collectDevicePostModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevicePostModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevicePostModel(item));
        }
        return result;
    }
    public CollectDeviceEntity collectDevicePutModel2entity(CollectDevicePutModel in) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId pressureUnit usingDate currentReading lastCollectTime resourceCode createTime outId regulatorDeviceProdFactory id state currentCellVoltage deptCode longitude currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public CollectDeviceEntity collectDevicePutModel2entity(CollectDevicePutModel in, CollectDeviceEntity ori) {
        //未转换字段: managementName createUserId updateUserId latitude isValid manageUserName updateTime installTime installAddress manageUserId pressureUnit usingDate currentReading lastCollectTime resourceCode createTime outId regulatorDeviceProdFactory id state currentCellVoltage deptCode longitude currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevicePutModelList2entityList(List<CollectDevicePutModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevicePutModel item : in) {
            result.add(collectDevicePutModel2entity(item));
        }
        return result;
    }
    public CollectDevicePutModel entity2collectDevicePutModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevicePutModel result = new CollectDevicePutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDevicePutModel> entityList2collectDevicePutModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevicePutModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevicePutModel(item));
        }
        return result;
    }
    public CollectDevicePutModel ext2collectDevicePutModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevicePutModel result = new CollectDevicePutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setCompanyId(HzhrTypeUtil.integer2integer(in.getCompanyId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setGasUserId(HzhrTypeUtil.integer2integer(in.getGasUserId()));
        result.setGasUserCode(HzhrTypeUtil.string2string(in.getGasUserCode()));
        result.setGasUserName(HzhrTypeUtil.string2string(in.getGasUserName()));
        result.setGasUserAddress(HzhrTypeUtil.string2string(in.getGasUserAddress()));
        result.setIotDeviceId(HzhrTypeUtil.integer2integer(in.getIotDeviceId()));
        return result;
    }
    public List<CollectDevicePutModel> extList2collectDevicePutModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevicePutModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevicePutModel(item));
        }
        return result;
    }
    public CollectDeviceEntity collectDevice1Model2entity(CollectDevice1Model in) {
        //未转换字段: createUserId code latitude manageUserId pressureUnit usingDate des gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setResourceCode(HzhrTypeUtil.string2string(in.getResourceCode()));
        result.setInstallTime(HzhrTypeUtil.long2date(in.getInstallTime()));
        return result;
    }
    public CollectDeviceEntity collectDevice1Model2entity(CollectDevice1Model in, CollectDeviceEntity ori) {
        //未转换字段: createUserId code latitude manageUserId pressureUnit usingDate des gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setResourceCode(HzhrTypeUtil.string2string(in.getResourceCode()));
        result.setInstallTime(HzhrTypeUtil.long2date(in.getInstallTime()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice1ModelList2entityList(List<CollectDevice1Model> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice1Model item : in) {
            result.add(collectDevice1Model2entity(item));
        }
        return result;
    }
    public CollectDevice1Model entity2collectDevice1Model(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice1Model result = new CollectDevice1Model();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setInstallTime(HzhrTypeUtil.date2long(in.getInstallTime()));
        result.setResourceCode(HzhrTypeUtil.string2string(in.getResourceCode()));
        return result;
    }
    public List<CollectDevice1Model> entityList2collectDevice1ModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice1Model> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice1Model(item));
        }
        return result;
    }
    public CollectDevice1Model ext2collectDevice1Model(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice1Model result = new CollectDevice1Model();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setInstallTime(HzhrTypeUtil.date2long(in.getInstallTime()));
        result.setResourceCode(HzhrTypeUtil.string2string(in.getResourceCode()));
        return result;
    }
    public List<CollectDevice1Model> extList2collectDevice1ModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice1Model> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice1Model(item));
        }
        return result;
    }
    public CollectDevice1GetModel extList2collectDevice1GetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDevice1Model> modelList = extList2collectDevice1ModelList(extList);
        if (modelList == null) {
            CollectDevice1GetModel result = new CollectDevice1GetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;

        if (!_show_info) {
            for (CollectDevice1Model model : modelList) {
                model.setCategoryCode(null);
                model.setResourceCode(null);
                model.setInstallTime(null);
            }
        }

        CollectDevice1GetModel result = new CollectDevice1GetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public CollectDevice1GetModel entity2collectDevice1GetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2collectDevice1GetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2collectDevice1GetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity collectDevice_CodeModel2entity(CollectDevice_CodeModel in) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public CollectDeviceEntity collectDevice_CodeModel2entity(CollectDevice_CodeModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_CodeModelList2entityList(List<CollectDevice_CodeModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_CodeModel item : in) {
            result.add(collectDevice_CodeModel2entity(item));
        }
        return result;
    }
    public CollectDevice_CodeModel entity2collectDevice_CodeModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_CodeModel result = new CollectDevice_CodeModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDevice_CodeModel> entityList2collectDevice_CodeModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_CodeModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_CodeModel(item));
        }
        return result;
    }
    public CollectDevice_CodeModel ext2collectDevice_CodeModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_CodeModel result = new CollectDevice_CodeModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDevice_CodeModel> extList2collectDevice_CodeModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_CodeModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_CodeModel(item));
        }
        return result;
    }
    public CollectDevice_CodeGetModel extList2collectDevice_CodeGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDevice_CodeModel> modelList = extList2collectDevice_CodeModelList(extList);
        if (modelList == null) {
            CollectDevice_CodeGetModel result = new CollectDevice_CodeGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;

        if (!_show_info) {
            for (CollectDevice_CodeModel model : modelList) {
                model.setCode(null);
            }
        }

        CollectDevice_CodeGetModel result = new CollectDevice_CodeGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public CollectDevice_CodeGetModel entity2collectDevice_CodeGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2collectDevice_CodeGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2collectDevice_CodeGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity collectDevice_CodePutModel2entity(CollectDevice_CodePutModel in) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public CollectDeviceEntity collectDevice_CodePutModel2entity(CollectDevice_CodePutModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_CodePutModelList2entityList(List<CollectDevice_CodePutModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_CodePutModel item : in) {
            result.add(collectDevice_CodePutModel2entity(item));
        }
        return result;
    }
    public CollectDevice_CodePutModel entity2collectDevice_CodePutModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_CodePutModel result = new CollectDevice_CodePutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDevice_CodePutModel> entityList2collectDevice_CodePutModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_CodePutModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_CodePutModel(item));
        }
        return result;
    }
    public CollectDevice_CodePutModel ext2collectDevice_CodePutModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_CodePutModel result = new CollectDevice_CodePutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        return result;
    }
    public List<CollectDevice_CodePutModel> extList2collectDevice_CodePutModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_CodePutModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_CodePutModel(item));
        }
        return result;
    }
    public CollectDeviceEntity collectDevice_StatusInfoModel2entity(CollectDevice_StatusInfoModel in) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress companyId createTime typeId deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        return result;
    }
    public CollectDeviceEntity collectDevice_StatusInfoModel2entity(CollectDevice_StatusInfoModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress companyId createTime typeId deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_StatusInfoModelList2entityList(List<CollectDevice_StatusInfoModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_StatusInfoModel item : in) {
            result.add(collectDevice_StatusInfoModel2entity(item));
        }
        return result;
    }
    public CollectDevice_StatusInfoModel entity2collectDevice_StatusInfoModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_StatusInfoModel result = new CollectDevice_StatusInfoModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDevice_StatusInfoModel> entityList2collectDevice_StatusInfoModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_StatusInfoModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_StatusInfoModel(item));
        }
        return result;
    }
    public CollectDevice_StatusInfoModel ext2collectDevice_StatusInfoModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_StatusInfoModel result = new CollectDevice_StatusInfoModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDevice_StatusInfoModel> extList2collectDevice_StatusInfoModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_StatusInfoModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_StatusInfoModel(item));
        }
        return result;
    }
    public CollectDevice_StatusInfoGetModel extList2collectDevice_StatusInfoGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDevice_StatusInfoModel> modelList = extList2collectDevice_StatusInfoModelList(extList);
        if (modelList == null) {
            CollectDevice_StatusInfoGetModel result = new CollectDevice_StatusInfoGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;

        if (!_show_info) {
            for (CollectDevice_StatusInfoModel model : modelList) {
                model.setCurrentReading(null);
                model.setCurrentValveStatusCode(null);
                model.setCurrentCellVoltage(null);
                model.setLastCollectTime(null);
            }
        }

        CollectDevice_StatusInfoGetModel result = new CollectDevice_StatusInfoGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public CollectDevice_StatusInfoGetModel entity2collectDevice_StatusInfoGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2collectDevice_StatusInfoGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2collectDevice_StatusInfoGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity collectDevice_StatusInfoPutModel2entity(CollectDevice_StatusInfoPutModel in) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress companyId createTime typeId deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        return result;
    }
    public CollectDeviceEntity collectDevice_StatusInfoPutModel2entity(CollectDevice_StatusInfoPutModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress companyId createTime typeId deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.long2date(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_StatusInfoPutModelList2entityList(List<CollectDevice_StatusInfoPutModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_StatusInfoPutModel item : in) {
            result.add(collectDevice_StatusInfoPutModel2entity(item));
        }
        return result;
    }
    public CollectDevice_StatusInfoPutModel entity2collectDevice_StatusInfoPutModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_StatusInfoPutModel result = new CollectDevice_StatusInfoPutModel();

        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDevice_StatusInfoPutModel> entityList2collectDevice_StatusInfoPutModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_StatusInfoPutModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_StatusInfoPutModel(item));
        }
        return result;
    }
    public CollectDevice_StatusInfoPutModel ext2collectDevice_StatusInfoPutModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_StatusInfoPutModel result = new CollectDevice_StatusInfoPutModel();

        result.setCurrentReading(HzhrTypeUtil.double2double(in.getCurrentReading()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        result.setCurrentCellVoltage(HzhrTypeUtil.float2float(in.getCurrentCellVoltage()));
        result.setLastCollectTime(HzhrTypeUtil.date2long(in.getLastCollectTime()));
        return result;
    }
    public List<CollectDevice_StatusInfoPutModel> extList2collectDevice_StatusInfoPutModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_StatusInfoPutModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_StatusInfoPutModel(item));
        }
        return result;
    }
    public CollectDeviceEntity collectDevice_ValveStatusModel2entity(CollectDevice_ValveStatusModel in) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public CollectDeviceEntity collectDevice_ValveStatusModel2entity(CollectDevice_ValveStatusModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_ValveStatusModelList2entityList(List<CollectDevice_ValveStatusModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_ValveStatusModel item : in) {
            result.add(collectDevice_ValveStatusModel2entity(item));
        }
        return result;
    }
    public CollectDevice_ValveStatusModel entity2collectDevice_ValveStatusModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_ValveStatusModel result = new CollectDevice_ValveStatusModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDevice_ValveStatusModel> entityList2collectDevice_ValveStatusModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_ValveStatusModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_ValveStatusModel(item));
        }
        return result;
    }
    public CollectDevice_ValveStatusModel ext2collectDevice_ValveStatusModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_ValveStatusModel result = new CollectDevice_ValveStatusModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDevice_ValveStatusModel> extList2collectDevice_ValveStatusModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_ValveStatusModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_ValveStatusModel(item));
        }
        return result;
    }
    public CollectDevice_ValveStatusGetModel extList2collectDevice_ValveStatusGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDevice_ValveStatusModel> modelList = extList2collectDevice_ValveStatusModelList(extList);
        if (modelList == null) {
            CollectDevice_ValveStatusGetModel result = new CollectDevice_ValveStatusGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;

        if (!_show_info) {
            for (CollectDevice_ValveStatusModel model : modelList) {
                model.setCurrentValveStatusCode(null);
            }
        }

        CollectDevice_ValveStatusGetModel result = new CollectDevice_ValveStatusGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public CollectDevice_ValveStatusGetModel entity2collectDevice_ValveStatusGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2collectDevice_ValveStatusGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2collectDevice_ValveStatusGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity collectDevice_ValveStatusPutModel2entity(CollectDevice_ValveStatusPutModel in) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public CollectDeviceEntity collectDevice_ValveStatusPutModel2entity(CollectDevice_ValveStatusPutModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId code latitude installTime manageUserId pressureUnit usingDate des resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDeviceEntity> collectDevice_ValveStatusPutModelList2entityList(List<CollectDevice_ValveStatusPutModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (CollectDevice_ValveStatusPutModel item : in) {
            result.add(collectDevice_ValveStatusPutModel2entity(item));
        }
        return result;
    }
    public CollectDevice_ValveStatusPutModel entity2collectDevice_ValveStatusPutModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_ValveStatusPutModel result = new CollectDevice_ValveStatusPutModel();

        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDevice_ValveStatusPutModel> entityList2collectDevice_ValveStatusPutModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<CollectDevice_ValveStatusPutModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2collectDevice_ValveStatusPutModel(item));
        }
        return result;
    }
    public CollectDevice_ValveStatusPutModel ext2collectDevice_ValveStatusPutModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        CollectDevice_ValveStatusPutModel result = new CollectDevice_ValveStatusPutModel();

        result.setCurrentValveStatusCode(HzhrTypeUtil.string2string(in.getCurrentValveStatusCode()));
        return result;
    }
    public List<CollectDevice_ValveStatusPutModel> extList2collectDevice_ValveStatusPutModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<CollectDevice_ValveStatusPutModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2collectDevice_ValveStatusPutModel(item));
        }
        return result;
    }
    public CollectDeviceEntity concentrator_MeterModel2entity(Concentrator_MeterModel in) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCreateTime(HzhrTypeUtil.long2date(in.getCreateTime()));
        return result;
    }
    public CollectDeviceEntity concentrator_MeterModel2entity(Concentrator_MeterModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCreateTime(HzhrTypeUtil.long2date(in.getCreateTime()));
        return result;
    }
    public List<CollectDeviceEntity> concentrator_MeterModelList2entityList(List<Concentrator_MeterModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (Concentrator_MeterModel item : in) {
            result.add(concentrator_MeterModel2entity(item));
        }
        return result;
    }
    public Concentrator_MeterModel entity2concentrator_MeterModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterModel result = new Concentrator_MeterModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCreateTime(HzhrTypeUtil.date2long(in.getCreateTime()));
        return result;
    }
    public List<Concentrator_MeterModel> entityList2concentrator_MeterModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<Concentrator_MeterModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2concentrator_MeterModel(item));
        }
        return result;
    }
    public Concentrator_MeterModel ext2concentrator_MeterModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterModel result = new Concentrator_MeterModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        result.setCreateTime(HzhrTypeUtil.date2long(in.getCreateTime()));
        return result;
    }
    public List<Concentrator_MeterModel> extList2concentrator_MeterModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<Concentrator_MeterModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2concentrator_MeterModel(item));
        }
        return result;
    }
    public Concentrator_MeterGetModel extList2concentrator_MeterGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<Concentrator_MeterModel> modelList = extList2concentrator_MeterModelList(extList);
        if (modelList == null) {
            Concentrator_MeterGetModel result = new Concentrator_MeterGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;

        if (!_show_info) {
            for (Concentrator_MeterModel model : modelList) {
                model.setCode(null);
                model.setDes(null);
                model.setCreateTime(null);
            }
        }

        Concentrator_MeterGetModel result = new Concentrator_MeterGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public Concentrator_MeterGetModel entity2concentrator_MeterGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2concentrator_MeterGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2concentrator_MeterGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceEntity concentrator_MeterPostModel2entity(Concentrator_MeterPostModel in) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public CollectDeviceEntity concentrator_MeterPostModel2entity(Concentrator_MeterPostModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<CollectDeviceEntity> concentrator_MeterPostModelList2entityList(List<Concentrator_MeterPostModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (Concentrator_MeterPostModel item : in) {
            result.add(concentrator_MeterPostModel2entity(item));
        }
        return result;
    }
    public Concentrator_MeterPostModel entity2concentrator_MeterPostModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterPostModel result = new Concentrator_MeterPostModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<Concentrator_MeterPostModel> entityList2concentrator_MeterPostModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<Concentrator_MeterPostModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2concentrator_MeterPostModel(item));
        }
        return result;
    }
    public Concentrator_MeterPostModel ext2concentrator_MeterPostModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterPostModel result = new Concentrator_MeterPostModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<Concentrator_MeterPostModel> extList2concentrator_MeterPostModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<Concentrator_MeterPostModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2concentrator_MeterPostModel(item));
        }
        return result;
    }
    public CollectDeviceEntity concentrator_MeterPutModel2entity(Concentrator_MeterPutModel in) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public CollectDeviceEntity concentrator_MeterPutModel2entity(Concentrator_MeterPutModel in, CollectDeviceEntity ori) {
        //未转换字段: createUserId latitude installTime manageUserId pressureUnit usingDate resourceCode gasUserCode outId regulatorDeviceProdFactory id state longitude currentValveStatusCode iotDeviceId managementName gasUserAddress gasUserName updateUserId isValid deptId gasUserId manageUserName updateTime categoryCode installAddress currentReading companyId lastCollectTime createTime typeId currentCellVoltage deptCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<CollectDeviceEntity> concentrator_MeterPutModelList2entityList(List<Concentrator_MeterPutModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (Concentrator_MeterPutModel item : in) {
            result.add(concentrator_MeterPutModel2entity(item));
        }
        return result;
    }
    public Concentrator_MeterPutModel entity2concentrator_MeterPutModel(CollectDeviceEntity in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterPutModel result = new Concentrator_MeterPutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<Concentrator_MeterPutModel> entityList2concentrator_MeterPutModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<Concentrator_MeterPutModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2concentrator_MeterPutModel(item));
        }
        return result;
    }
    public Concentrator_MeterPutModel ext2concentrator_MeterPutModel(CollectDeviceEntityExt in) {
        //未转换字段: 
        if (in == null) return null;
        Concentrator_MeterPutModel result = new Concentrator_MeterPutModel();

        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setDes(HzhrTypeUtil.string2string(in.getDes()));
        return result;
    }
    public List<Concentrator_MeterPutModel> extList2concentrator_MeterPutModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<Concentrator_MeterPutModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2concentrator_MeterPutModel(item));
        }
        return result;
    }
    public CollectDeviceEntity regulatorDeviceModel2entity(RegulatorDeviceModel in) {
        //未转换字段: iotDeviceId managementName gasUserAddress createUserId gasUserName updateUserId isValid gasUserId updateTime installTime pressureUnit currentReading companyId des lastCollectTime resourceCode createTime gasUserCode outId state currentCellVoltage deptCode currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = new CollectDeviceEntity();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setManageUserId(HzhrTypeUtil.integer2integer(in.getManageUserId()));
        result.setManageUserName(HzhrTypeUtil.string2string(in.getManageUserName()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setInstallAddress(HzhrTypeUtil.string2string(in.getInstallAddress()));
        result.setUsingDate(HzhrTypeUtil.long2date(in.getUsingDate()));
        result.setRegulatorDeviceProdFactory(HzhrTypeUtil.string2string(in.getProdFactoryDes()));
        result.setLongitude(HzhrTypeUtil.double2double(in.getLongitude()));
        result.setLatitude(HzhrTypeUtil.double2double(in.getLatitude()));
        return result;
    }
    public CollectDeviceEntity regulatorDeviceModel2entity(RegulatorDeviceModel in, CollectDeviceEntity ori) {
        //未转换字段: iotDeviceId managementName gasUserAddress createUserId gasUserName updateUserId isValid gasUserId updateTime installTime pressureUnit currentReading companyId des lastCollectTime resourceCode createTime gasUserCode outId state currentCellVoltage deptCode currentValveStatusCode 
        if (in == null) return null;
        CollectDeviceEntity result = ori;

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setManageUserId(HzhrTypeUtil.integer2integer(in.getManageUserId()));
        result.setManageUserName(HzhrTypeUtil.string2string(in.getManageUserName()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setInstallAddress(HzhrTypeUtil.string2string(in.getInstallAddress()));
        result.setUsingDate(HzhrTypeUtil.long2date(in.getUsingDate()));
        result.setRegulatorDeviceProdFactory(HzhrTypeUtil.string2string(in.getProdFactoryDes()));
        result.setLongitude(HzhrTypeUtil.double2double(in.getLongitude()));
        result.setLatitude(HzhrTypeUtil.double2double(in.getLatitude()));
        return result;
    }
    public List<CollectDeviceEntity> regulatorDeviceModelList2entityList(List<RegulatorDeviceModel> in) {
        if (in == null) return null;
        List<CollectDeviceEntity> result = new ArrayList<>();
        for (RegulatorDeviceModel item : in) {
            result.add(regulatorDeviceModel2entity(item));
        }
        return result;
    }
    public RegulatorDeviceModel entity2regulatorDeviceModel(CollectDeviceEntity in) {
        //未转换字段: managementName qrCode subCompanyName categoryDes typeDes 
        if (in == null) return null;
        RegulatorDeviceModel result = new RegulatorDeviceModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setInstallAddress(HzhrTypeUtil.string2string(in.getInstallAddress()));
        result.setLongitude(HzhrTypeUtil.double2double(in.getLongitude()));
        result.setLatitude(HzhrTypeUtil.double2double(in.getLatitude()));
        result.setUsingDate(HzhrTypeUtil.date2long(in.getUsingDate()));
        result.setManageUserId(HzhrTypeUtil.integer2integer(in.getManageUserId()));
        result.setManageUserName(HzhrTypeUtil.string2string(in.getManageUserName()));
        result.setProdFactoryDes(HzhrTypeUtil.string2string(in.getRegulatorDeviceProdFactory()));
        return result;
    }
    public List<RegulatorDeviceModel> entityList2regulatorDeviceModelList(List<CollectDeviceEntity> in) {
        if (in == null) return null;
        List<RegulatorDeviceModel> result = new ArrayList<>();
        for (CollectDeviceEntity item : in) {
            result.add(entity2regulatorDeviceModel(item));
        }
        return result;
    }
    public RegulatorDeviceModel ext2regulatorDeviceModel(CollectDeviceEntityExt in) {
        //未转换字段: managementName qrCode subCompanyName categoryDes typeDes 
        if (in == null) return null;
        RegulatorDeviceModel result = new RegulatorDeviceModel();

        result.setId(HzhrTypeUtil.integer2integer(in.getId()));
        result.setCode(HzhrTypeUtil.string2string(in.getCode()));
        result.setCategoryCode(HzhrTypeUtil.string2string(in.getCategoryCode()));
        result.setTypeId(HzhrTypeUtil.integer2integer(in.getTypeId()));
        result.setDeptId(HzhrTypeUtil.integer2integer(in.getDeptId()));
        result.setInstallAddress(HzhrTypeUtil.string2string(in.getInstallAddress()));
        result.setLongitude(HzhrTypeUtil.double2double(in.getLongitude()));
        result.setLatitude(HzhrTypeUtil.double2double(in.getLatitude()));
        result.setUsingDate(HzhrTypeUtil.date2long(in.getUsingDate()));
        result.setManageUserId(HzhrTypeUtil.integer2integer(in.getManageUserId()));
        result.setManageUserName(HzhrTypeUtil.string2string(in.getManageUserName()));
        result.setProdFactoryDes(HzhrTypeUtil.string2string(in.getRegulatorDeviceProdFactory()));
        return result;
    }
    public List<RegulatorDeviceModel> extList2regulatorDeviceModelList(List<CollectDeviceEntityExt> in) {
        if (in == null) return null;
        List<RegulatorDeviceModel> result = new ArrayList<>();
        for (CollectDeviceEntityExt item : in) {
            result.add(ext2regulatorDeviceModel(item));
        }
        return result;
    }
    public RegulatorDeviceGetModel extList2regulatorDeviceGetModel(List<CollectDeviceEntityExt> extList, Integer total, Integer changeCount, Map<String, Object> query) {
        List<RegulatorDeviceModel> modelList = extList2regulatorDeviceModelList(extList);
        if (modelList == null) {
            RegulatorDeviceGetModel result = new RegulatorDeviceGetModel();
            result.setTotal(total);
            result.setChangeCount(changeCount);
            return result;
        }

         String _show = HzhrTypeUtil.object2string(query.get("_show"));
         Boolean _show_subCompanyName = query.get("_show_subCompanyName") != null ? Boolean.parseBoolean(query.get("_show_subCompanyName").toString()) : false;
         Boolean _show_info = query.get("_show_info") != null ? Boolean.parseBoolean(query.get("_show_info").toString()) : false;
         Boolean _show_managementName = query.get("_show_managementName") != null ? Boolean.parseBoolean(query.get("_show_managementName").toString()) : false;

        if (!_show_subCompanyName) {
            for (RegulatorDeviceModel model : modelList) {
                model.setSubCompanyName(null);
            }
        }
        if (!_show_info) {
            for (RegulatorDeviceModel model : modelList) {
                model.setCode(null);
                model.setCategoryCode(null);
                model.setCategoryDes(null);
                model.setDeptId(null);
                model.setManageUserId(null);
                model.setManageUserName(null);
                model.setTypeId(null);
                model.setTypeDes(null);
                model.setInstallAddress(null);
                model.setUsingDate(null);
                model.setProdFactoryDes(null);
                model.setQrCode(null);
                model.setLongitude(null);
                model.setLatitude(null);
            }
        }
        if (!_show_managementName) {
            for (RegulatorDeviceModel model : modelList) {
                model.setManagementName(null);
            }
        }

        RegulatorDeviceGetModel result = new RegulatorDeviceGetModel();
        if ("one".equals(_show)) {
            if (modelList.size() > 0) {
                result.setModel(modelList.get(0));
            }
         }
        if ("list".equals(_show)) {
            result.setModelList(modelList);
        }
        result.setTotal(total);
        result.setChangeCount(changeCount);
        return result;
    }
    public RegulatorDeviceGetModel entity2regulatorDeviceGetModel(CollectDeviceEntity entity, Integer total, Integer changeCount, Map<String, Object> query) {
        List<CollectDeviceEntityExt> extList = new ArrayList<>();
        if (entity == null) return extList2regulatorDeviceGetModel(extList, total, changeCount, query);
        extList.add(HzhrJsonUtil.convertObjectType(entity, CollectDeviceEntityExt.class));
        return extList2regulatorDeviceGetModel(extList, total, changeCount, query);
     }
    public CollectDeviceCustomQueryModel collectDevice1Service_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        String _equal_categoryCode = HzhrTypeUtil.object2string(query.get("_equal_categoryCode"));
        if (_equal_categoryCode != null) {
            queryModel.setEqual_categoryCode(_equal_categoryCode);
         }

        String _like_resourceCode = HzhrTypeUtil.object2string(query.get("_like_resourceCode"));
        if (_like_resourceCode != null) {
            queryModel.setLike_resourceCode(_like_resourceCode);
         }

        Date _greaterthanorequal_installTime = HzhrTypeUtil.object2date(query.get("_greaterthanorequal_installTime"));
        if (_greaterthanorequal_installTime != null) {
            queryModel.setGreaterthanorequal_installTime(_greaterthanorequal_installTime);
         }

        Date _lessthan_installTime = HzhrTypeUtil.object2date(query.get("_lessthan_installTime"));
        if (_lessthan_installTime != null) {
            queryModel.setLessthan_installTime(_lessthan_installTime);
         }

        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel collectDeviceQuickqueryService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        String _equal_code = HzhrTypeUtil.object2string(query.get("_equal_code"));
        if (_equal_code != null) {
            queryModel.setEqual_code(_equal_code);
         }

        Integer _equal_companyId = HzhrTypeUtil.object2integer(query.get("_equal_companyId"));
        if (_equal_companyId != null) {
            queryModel.setEqual_companyId(_equal_companyId);
         }

        Integer _equal_deptId = HzhrTypeUtil.object2integer(query.get("_equal_deptId"));
        if (_equal_deptId != null) {
            queryModel.setEqual_deptId(_equal_deptId);
         }

        String _equal_deptCode = HzhrTypeUtil.object2string(query.get("_equal_deptCode"));
        if (_equal_deptCode != null) {
            queryModel.setEqual_deptCode(_equal_deptCode);
         }

        String _equal_categoryCode = HzhrTypeUtil.object2string(query.get("_equal_categoryCode"));
        if (_equal_categoryCode != null) {
            queryModel.setEqual_categoryCode(_equal_categoryCode);
         }

        String _like_code = HzhrTypeUtil.object2string(query.get("_like_code"));
        if (_like_code != null) {
            queryModel.setLike_code(_like_code);
         }

        Integer _equal_iotDeviceId = HzhrTypeUtil.object2integer(query.get("_equal_iotDeviceId"));
        if (_equal_iotDeviceId != null) {
            queryModel.setEqual_iotDeviceId(_equal_iotDeviceId);
         }

        String _like_iotDeviceCode = HzhrTypeUtil.object2string(query.get("_like_iotDeviceCode"));
        if (_like_iotDeviceCode != null) {
            queryModel.setLike_iotDeviceExt_code(_like_iotDeviceCode);
         }

        String _like_gasUserName = HzhrTypeUtil.object2string(query.get("_like_gasUserName"));
        if (_like_gasUserName != null) {
            queryModel.setLike_gasUserName(_like_gasUserName);
         }

        String _like_gasUserCode = HzhrTypeUtil.object2string(query.get("_like_gasUserCode"));
        if (_like_gasUserCode != null) {
            queryModel.setLike_gasUserCode(_like_gasUserCode);
         }

        String _like_gasUserAddress = HzhrTypeUtil.object2string(query.get("_like_gasUserAddress"));
        if (_like_gasUserAddress != null) {
            queryModel.setLike_gasUserAddress(_like_gasUserAddress);
         }

        Date _greaterthanorequal_createTime = HzhrTypeUtil.object2date(query.get("_greaterthanorequal_createTime"));
        if (_greaterthanorequal_createTime != null) {
            queryModel.setGreaterthanorequal_createTime(_greaterthanorequal_createTime);
         }

        Date _lessthan_createTime = HzhrTypeUtil.object2date(query.get("_lessthan_createTime"));
        if (_lessthan_createTime != null) {
            queryModel.setLessthan_createTime(_lessthan_createTime);
         }

        Integer _equal_gasUserId = HzhrTypeUtil.object2integer(query.get("_equal_gasUserId"));
        if (_equal_gasUserId != null) {
            queryModel.setEqual_gasUserId(_equal_gasUserId);
         }

        Integer _equal_prodFactoryId = HzhrTypeUtil.object2integer(query.get("_equal_prodFactoryId"));
        if (_equal_prodFactoryId != null) {
            queryModel.setEqual_typeExt_prodFactoryId(_equal_prodFactoryId);
         }

        String _equal_iotDeviceCompanyName = HzhrTypeUtil.object2string(query.get("_equal_iotDeviceCompanyName"));
        if (_equal_iotDeviceCompanyName != null) {
            queryModel.setEqual_iotDeviceExt_companyExt_name(_equal_iotDeviceCompanyName);
         }

        String _equal_gasUserCode = HzhrTypeUtil.object2string(query.get("_equal_gasUserCode"));
        if (_equal_gasUserCode != null) {
            queryModel.setEqual_gasUserCode(_equal_gasUserCode);
         }

        String _like_deptCode = HzhrTypeUtil.object2string(query.get("_like_deptCode"));
        if (_like_deptCode != null) {
            queryModel.setLike_deptCode(_like_deptCode);
         }

        Integer _equal_iotDeviceCompanyId = HzhrTypeUtil.object2integer(query.get("_equal_iotDeviceCompanyId"));
        if (_equal_iotDeviceCompanyId != null) {
            queryModel.setEqual_iotDeviceExt_companyId(_equal_iotDeviceCompanyId);
         }

        Integer _equal_prodFactoryIotCompanyId = HzhrTypeUtil.object2integer(query.get("_equal_prodFactoryIotCompanyId"));
        if (_equal_prodFactoryIotCompanyId != null) {
            queryModel.setEqual_typeExt_prodFactoryExt_iotCompanyId(_equal_prodFactoryIotCompanyId);
         }

        Boolean _show_gasUser = HzhrTypeUtil.object2boolean(query.get("_show_gasUser"));
        if (_show_gasUser != null && _show_gasUser) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_type = HzhrTypeUtil.object2boolean(query.get("_show_type"));
        if (_show_type != null && _show_type) {
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
        }
        Boolean _show_outId = HzhrTypeUtil.object2boolean(query.get("_show_outId"));
        if (_show_outId != null && _show_outId) {
            queryModel.setShow(true);
        }
        Boolean _show_iotDevice = HzhrTypeUtil.object2boolean(query.get("_show_iotDevice"));
        if (_show_iotDevice != null && _show_iotDevice) {
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_typeExt(true);
            queryModel.setShow7(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_simTypeExt(true);
            queryModel.setShow8(true);
            queryModel.setExt_iotDeviceExt_companyExt(true);
            queryModel.setShow25(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_pressureUnitExt(true);
            queryModel.setShow14(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_currentValveStatusExt(true);
            queryModel.setShow11(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_gasConsume = HzhrTypeUtil.object2boolean(query.get("_show_gasConsume"));
        if (_show_gasConsume != null && _show_gasConsume) {
            queryModel.setShow(true);
        }
        Boolean _show_alarmCount = HzhrTypeUtil.object2boolean(query.get("_show_alarmCount"));
        if (_show_alarmCount != null && _show_alarmCount) {
            queryModel.setShow(true);
        }
        Boolean _show_dept = HzhrTypeUtil.object2boolean(query.get("_show_dept"));
        if (_show_dept != null && _show_dept) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel collectDeviceService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        String _equal_code = HzhrTypeUtil.object2string(query.get("_equal_code"));
        if (_equal_code != null) {
            queryModel.setEqual_code(_equal_code);
         }

        Integer _equal_companyId = HzhrTypeUtil.object2integer(query.get("_equal_companyId"));
        if (_equal_companyId != null) {
            queryModel.setEqual_companyId(_equal_companyId);
         }

        Integer _equal_deptId = HzhrTypeUtil.object2integer(query.get("_equal_deptId"));
        if (_equal_deptId != null) {
            queryModel.setEqual_deptId(_equal_deptId);
         }

        String _equal_deptCode = HzhrTypeUtil.object2string(query.get("_equal_deptCode"));
        if (_equal_deptCode != null) {
            queryModel.setEqual_deptCode(_equal_deptCode);
         }

        String _equal_categoryCode = HzhrTypeUtil.object2string(query.get("_equal_categoryCode"));
        if (_equal_categoryCode != null) {
            queryModel.setEqual_categoryCode(_equal_categoryCode);
         }

        String _like_code = HzhrTypeUtil.object2string(query.get("_like_code"));
        if (_like_code != null) {
            queryModel.setLike_code(_like_code);
         }

        Integer _equal_iotDeviceId = HzhrTypeUtil.object2integer(query.get("_equal_iotDeviceId"));
        if (_equal_iotDeviceId != null) {
            queryModel.setEqual_iotDeviceId(_equal_iotDeviceId);
         }

        String _like_iotDeviceCode = HzhrTypeUtil.object2string(query.get("_like_iotDeviceCode"));
        if (_like_iotDeviceCode != null) {
            queryModel.setLike_iotDeviceExt_code(_like_iotDeviceCode);
         }

        String _like_gasUserName = HzhrTypeUtil.object2string(query.get("_like_gasUserName"));
        if (_like_gasUserName != null) {
            queryModel.setLike_gasUserName(_like_gasUserName);
         }

        String _like_gasUserCode = HzhrTypeUtil.object2string(query.get("_like_gasUserCode"));
        if (_like_gasUserCode != null) {
            queryModel.setLike_gasUserCode(_like_gasUserCode);
         }

        String _like_gasUserAddress = HzhrTypeUtil.object2string(query.get("_like_gasUserAddress"));
        if (_like_gasUserAddress != null) {
            queryModel.setLike_gasUserAddress(_like_gasUserAddress);
         }

        Date _greaterthanorequal_createTime = HzhrTypeUtil.object2date(query.get("_greaterthanorequal_createTime"));
        if (_greaterthanorequal_createTime != null) {
            queryModel.setGreaterthanorequal_createTime(_greaterthanorequal_createTime);
         }

        Date _lessthan_createTime = HzhrTypeUtil.object2date(query.get("_lessthan_createTime"));
        if (_lessthan_createTime != null) {
            queryModel.setLessthan_createTime(_lessthan_createTime);
         }

        Integer _equal_gasUserId = HzhrTypeUtil.object2integer(query.get("_equal_gasUserId"));
        if (_equal_gasUserId != null) {
            queryModel.setEqual_gasUserId(_equal_gasUserId);
         }

        Integer _equal_prodFactoryId = HzhrTypeUtil.object2integer(query.get("_equal_prodFactoryId"));
        if (_equal_prodFactoryId != null) {
            queryModel.setEqual_typeExt_prodFactoryId(_equal_prodFactoryId);
         }

        String _equal_iotDeviceCompanyName = HzhrTypeUtil.object2string(query.get("_equal_iotDeviceCompanyName"));
        if (_equal_iotDeviceCompanyName != null) {
            queryModel.setEqual_iotDeviceExt_companyExt_name(_equal_iotDeviceCompanyName);
         }

        String _equal_gasUserCode = HzhrTypeUtil.object2string(query.get("_equal_gasUserCode"));
        if (_equal_gasUserCode != null) {
            queryModel.setEqual_gasUserCode(_equal_gasUserCode);
         }

        String _like_deptCode = HzhrTypeUtil.object2string(query.get("_like_deptCode"));
        if (_like_deptCode != null) {
            queryModel.setLike_deptCode(_like_deptCode);
         }

        Integer _equal_iotDeviceCompanyId = HzhrTypeUtil.object2integer(query.get("_equal_iotDeviceCompanyId"));
        if (_equal_iotDeviceCompanyId != null) {
            queryModel.setEqual_iotDeviceExt_companyId(_equal_iotDeviceCompanyId);
         }

        Integer _equal_prodFactoryIotCompanyId = HzhrTypeUtil.object2integer(query.get("_equal_prodFactoryIotCompanyId"));
        if (_equal_prodFactoryIotCompanyId != null) {
            queryModel.setEqual_typeExt_prodFactoryExt_iotCompanyId(_equal_prodFactoryIotCompanyId);
         }

        Boolean _show_gasUser = HzhrTypeUtil.object2boolean(query.get("_show_gasUser"));
        if (_show_gasUser != null && _show_gasUser) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_type = HzhrTypeUtil.object2boolean(query.get("_show_type"));
        if (_show_type != null && _show_type) {
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
        }
        Boolean _show_outId = HzhrTypeUtil.object2boolean(query.get("_show_outId"));
        if (_show_outId != null && _show_outId) {
            queryModel.setShow(true);
        }
        Boolean _show_iotDevice = HzhrTypeUtil.object2boolean(query.get("_show_iotDevice"));
        if (_show_iotDevice != null && _show_iotDevice) {
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_typeExt(true);
            queryModel.setShow7(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_simTypeExt(true);
            queryModel.setShow8(true);
            queryModel.setExt_iotDeviceExt_companyExt(true);
            queryModel.setShow25(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_pressureUnitExt(true);
            queryModel.setShow14(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_currentValveStatusExt(true);
            queryModel.setShow11(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_gasConsume = HzhrTypeUtil.object2boolean(query.get("_show_gasConsume"));
        if (_show_gasConsume != null && _show_gasConsume) {
            queryModel.setShow(true);
        }
        Boolean _show_alarmCount = HzhrTypeUtil.object2boolean(query.get("_show_alarmCount"));
        if (_show_alarmCount != null && _show_alarmCount) {
            queryModel.setShow(true);
        }
        Boolean _show_dept = HzhrTypeUtil.object2boolean(query.get("_show_dept"));
        if (_show_dept != null && _show_dept) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel collectDevice_CodeService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        Boolean _show_gasUser = HzhrTypeUtil.object2boolean(query.get("_show_gasUser"));
        if (_show_gasUser != null && _show_gasUser) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_type = HzhrTypeUtil.object2boolean(query.get("_show_type"));
        if (_show_type != null && _show_type) {
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
        }
        Boolean _show_outId = HzhrTypeUtil.object2boolean(query.get("_show_outId"));
        if (_show_outId != null && _show_outId) {
            queryModel.setShow(true);
        }
        Boolean _show_iotDevice = HzhrTypeUtil.object2boolean(query.get("_show_iotDevice"));
        if (_show_iotDevice != null && _show_iotDevice) {
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_typeExt(true);
            queryModel.setShow7(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_simTypeExt(true);
            queryModel.setShow8(true);
            queryModel.setExt_iotDeviceExt_companyExt(true);
            queryModel.setShow25(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_pressureUnitExt(true);
            queryModel.setShow14(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_currentValveStatusExt(true);
            queryModel.setShow11(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_gasConsume = HzhrTypeUtil.object2boolean(query.get("_show_gasConsume"));
        if (_show_gasConsume != null && _show_gasConsume) {
            queryModel.setShow(true);
        }
        Boolean _show_alarmCount = HzhrTypeUtil.object2boolean(query.get("_show_alarmCount"));
        if (_show_alarmCount != null && _show_alarmCount) {
            queryModel.setShow(true);
        }
        Boolean _show_dept = HzhrTypeUtil.object2boolean(query.get("_show_dept"));
        if (_show_dept != null && _show_dept) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel collectDevice_StatusInfoService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        Boolean _show_gasUser = HzhrTypeUtil.object2boolean(query.get("_show_gasUser"));
        if (_show_gasUser != null && _show_gasUser) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_type = HzhrTypeUtil.object2boolean(query.get("_show_type"));
        if (_show_type != null && _show_type) {
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
        }
        Boolean _show_outId = HzhrTypeUtil.object2boolean(query.get("_show_outId"));
        if (_show_outId != null && _show_outId) {
            queryModel.setShow(true);
        }
        Boolean _show_iotDevice = HzhrTypeUtil.object2boolean(query.get("_show_iotDevice"));
        if (_show_iotDevice != null && _show_iotDevice) {
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_typeExt(true);
            queryModel.setShow7(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_simTypeExt(true);
            queryModel.setShow8(true);
            queryModel.setExt_iotDeviceExt_companyExt(true);
            queryModel.setShow25(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_pressureUnitExt(true);
            queryModel.setShow14(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_currentValveStatusExt(true);
            queryModel.setShow11(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_gasConsume = HzhrTypeUtil.object2boolean(query.get("_show_gasConsume"));
        if (_show_gasConsume != null && _show_gasConsume) {
            queryModel.setShow(true);
        }
        Boolean _show_alarmCount = HzhrTypeUtil.object2boolean(query.get("_show_alarmCount"));
        if (_show_alarmCount != null && _show_alarmCount) {
            queryModel.setShow(true);
        }
        Boolean _show_dept = HzhrTypeUtil.object2boolean(query.get("_show_dept"));
        if (_show_dept != null && _show_dept) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel collectDevice_ValveStatusService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        Boolean _show_gasUser = HzhrTypeUtil.object2boolean(query.get("_show_gasUser"));
        if (_show_gasUser != null && _show_gasUser) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_type = HzhrTypeUtil.object2boolean(query.get("_show_type"));
        if (_show_type != null && _show_type) {
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
            queryModel.setExt_typeExt_prodFactoryExt(true);
            queryModel.setShow10(true);
        }
        Boolean _show_outId = HzhrTypeUtil.object2boolean(query.get("_show_outId"));
        if (_show_outId != null && _show_outId) {
            queryModel.setShow(true);
        }
        Boolean _show_iotDevice = HzhrTypeUtil.object2boolean(query.get("_show_iotDevice"));
        if (_show_iotDevice != null && _show_iotDevice) {
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_typeExt(true);
            queryModel.setShow7(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt(true);
            queryModel.setShow9(true);
            queryModel.setExt_iotDeviceExt_simTypeExt(true);
            queryModel.setShow8(true);
            queryModel.setExt_iotDeviceExt_companyExt(true);
            queryModel.setShow25(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_pressureUnitExt(true);
            queryModel.setShow14(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_currentValveStatusExt(true);
            queryModel.setShow11(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_gasConsume = HzhrTypeUtil.object2boolean(query.get("_show_gasConsume"));
        if (_show_gasConsume != null && _show_gasConsume) {
            queryModel.setShow(true);
        }
        Boolean _show_alarmCount = HzhrTypeUtil.object2boolean(query.get("_show_alarmCount"));
        if (_show_alarmCount != null && _show_alarmCount) {
            queryModel.setShow(true);
        }
        Boolean _show_dept = HzhrTypeUtil.object2boolean(query.get("_show_dept"));
        if (_show_dept != null && _show_dept) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel concentrator_MeterService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        String _equal_code = HzhrTypeUtil.object2string(query.get("_equal_code"));
        if (_equal_code != null) {
            queryModel.setEqual_code(_equal_code);
         }

        String _like_des = HzhrTypeUtil.object2string(query.get("_like_des"));
        if (_like_des != null) {
            queryModel.setLike_des(_like_des);
         }

        Date _greaterthanorequal_createTime = HzhrTypeUtil.object2date(query.get("_greaterthanorequal_createTime"));
        if (_greaterthanorequal_createTime != null) {
            queryModel.setGreaterthanorequal_createTime(_greaterthanorequal_createTime);
         }

        Date _lessthan_createTime = HzhrTypeUtil.object2date(query.get("_lessthan_createTime"));
        if (_lessthan_createTime != null) {
            queryModel.setLessthan_createTime(_lessthan_createTime);
         }

        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }
    public CollectDeviceCustomQueryModel regulatorDeviceService_query2queryModel(Map<String, Object> query) {
        CollectDeviceCustomQueryModel queryModel = new CollectDeviceCustomQueryModel();

        Integer _equal_id = HzhrTypeUtil.object2integer(query.get("_equal_id"));
        if (_equal_id != null) {
            queryModel.setEqual_id(_equal_id);
         }

        String _equal_code = HzhrTypeUtil.object2string(query.get("_equal_code"));
        if (_equal_code != null) {
            queryModel.setEqual_code(_equal_code);
         }

        String _like_code = HzhrTypeUtil.object2string(query.get("_like_code"));
        if (_like_code != null) {
            queryModel.setLike_code(_like_code);
         }

        String _equal_categoryCode = HzhrTypeUtil.object2string(query.get("_equal_categoryCode"));
        if (_equal_categoryCode != null) {
            queryModel.setEqual_categoryCode(_equal_categoryCode);
         }

        Integer _equal_deptId = HzhrTypeUtil.object2integer(query.get("_equal_deptId"));
        if (_equal_deptId != null) {
            queryModel.setEqual_deptId(_equal_deptId);
         }

        Boolean _show_subCompanyName = HzhrTypeUtil.object2boolean(query.get("_show_subCompanyName"));
        if (_show_subCompanyName != null && _show_subCompanyName) {
            queryModel.setShow(true);
        }
        Boolean _show_info = HzhrTypeUtil.object2boolean(query.get("_show_info"));
        if (_show_info != null && _show_info) {
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_categoryExt(true);
            queryModel.setShow19(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setExt_typeExt(true);
            queryModel.setShow1(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
            queryModel.setShow(true);
        }
        Boolean _show_managementName = HzhrTypeUtil.object2boolean(query.get("_show_managementName"));
        if (_show_managementName != null && _show_managementName) {
            queryModel.setShow(true);
        }

        Integer page = HzhrTypeUtil.object2integer(query.get("_page"));
        Integer count = HzhrTypeUtil.object2integer(query.get("_count"));
        queryModel.setPage(page, count);

        return queryModel;
    }

}

